import Vue from 'vue'
import VueRouter from 'vue-router'


Vue.use(VueRouter)

const routes = [
  {
    path: '/login',
    name: 'login',
    component: () => import( '../views/login.vue')

  },
  {
    path: '/index',
    name: 'index',
    component: () => import( '../views/index'),
    children:[
      {
        path: '/homa',
        name: 'homa',
        component: () => import( '../views/homa/homa'),
      },
      {
        path: '/organi',
        name: 'organi',
        component: () => import( '../views/organi/organi'),
      },
      {
        path: '/dietass',
        name: 'dietass',
        component: () => import( '../views/dietas/dietass'),
     
      },
      {
        path: '/supplier',
        name: 'supplier',
        component: () => import( '../views/supplier/supplier'),
     
      },
      {
        path: '/purchase',
        name: 'purchase',
        component: () => import( '../views/purchase/purchase'),
     
      },
   
      {
        path: '/role',
        name: 'role',
        component: () => import( '../views/role/role'),
     
      },
      {
        path: '/account',
        name: 'account',
        component: () => import( '../views/account/account'),
     
      },
      {
          path:'/management',
          name: 'management',
          component: () => import( '../views/management/management'),
      }
    ]

   },
 
]

const router = new VueRouter({
  routes
})

export default router
